home *** CD-ROM | disk | FTP | other *** search
/ Die Ultimative Software-P…i Collection 1996 & 1997 / Die Ultimative Software-Pakete CD-ROM fur Atari Collection 1996 & 1997.iso / g / gnu_c / info.lzh / INFO / GCC_INFO.12 < prev    next >
Encoding:
GNU Info File  |  1993-10-21  |  49.0 KB  |  1,269 lines

  1. This is Info file gcc.info, produced by Makeinfo-1.54 from the input
  2. file gcc.texi.
  3.  
  4.    This file documents the use and the internals of the GNU compiler.
  5.  
  6.    Copyright (C) 1988, 1989, 1992, 1993 Free Software Foundation, Inc.
  7.  
  8.    Permission is granted to make and distribute verbatim copies of this
  9. manual provided the copyright notice and this permission notice are
  10. preserved on all copies.
  11.  
  12.    Permission is granted to copy and distribute modified versions of
  13. this manual under the conditions for verbatim copying, provided also
  14. that the sections entitled "GNU General Public License" and "Protect
  15. Your Freedom--Fight `Look And Feel'" are included exactly as in the
  16. original, and provided that the entire resulting derived work is
  17. distributed under the terms of a permission notice identical to this
  18. one.
  19.  
  20.    Permission is granted to copy and distribute translations of this
  21. manual into another language, under the above conditions for modified
  22. versions, except that the sections entitled "GNU General Public
  23. License" and "Protect Your Freedom--Fight `Look And Feel'", and this
  24. permission notice, may be included in translations approved by the Free
  25. Software Foundation instead of in the original English.
  26.  
  27. File: gcc.info,  Node: RTL Template,  Next: Output Template,  Prev: Example,  Up: Machine Desc
  28.  
  29. RTL Template for Generating and Recognizing Insns
  30. =================================================
  31.  
  32.    The RTL template is used to define which insns match the particular
  33. pattern and how to find their operands.  For named patterns, the RTL
  34. template also says how to construct an insn from specified operands.
  35.  
  36.    Construction involves substituting specified operands into a copy of
  37. the template.  Matching involves determining the values that serve as
  38. the operands in the insn being matched.  Both of these activities are
  39. controlled by special expression types that direct matching and
  40. substitution of the operands.
  41.  
  42. `(match_operand:M N PREDICATE CONSTRAINT)'
  43.      This expression is a placeholder for operand number N of the insn.
  44.      When constructing an insn, operand number N will be substituted
  45.      at this point.  When matching an insn, whatever appears at this
  46.      position in the insn will be taken as operand number N; but it
  47.      must satisfy PREDICATE or this instruction pattern will not match
  48.      at all.
  49.  
  50.      Operand numbers must be chosen consecutively counting from zero in
  51.      each instruction pattern.  There may be only one `match_operand'
  52.      expression in the pattern for each operand number.  Usually
  53.      operands are numbered in the order of appearance in `match_operand'
  54.      expressions.
  55.  
  56.      PREDICATE is a string that is the name of a C function that
  57.      accepts two arguments, an expression and a machine mode.  During
  58.      matching, the function will be called with the putative operand as
  59.      the expression and M as the mode argument (if M is not specified,
  60.      `VOIDmode' will be used, which normally causes PREDICATE to accept
  61.      any mode).  If it returns zero, this instruction pattern fails to
  62.      match.  PREDICATE may be an empty string; then it means no test is
  63.      to be done on the operand, so anything which occurs in this
  64.      position is valid.
  65.  
  66.      Most of the time, PREDICATE will reject modes other than M--but
  67.      not always.  For example, the predicate `address_operand' uses M
  68.      as the mode of memory ref that the address should be valid for.
  69.      Many predicates accept `const_int' nodes even though their mode is
  70.      `VOIDmode'.
  71.  
  72.      CONSTRAINT controls reloading and the choice of the best register
  73.      class to use for a value, as explained later (*note
  74.      Constraints::.).
  75.  
  76.      People are often unclear on the difference between the constraint
  77.      and the predicate.  The predicate helps decide whether a given
  78.      insn matches the pattern.  The constraint plays no role in this
  79.      decision; instead, it controls various decisions in the case of an
  80.      insn which does match.
  81.  
  82.      On CISC machines, PREDICATE is most often `"general_operand"'.
  83.      This function checks that the putative operand is either a
  84.      constant, a register or a memory reference, and that it is valid
  85.      for mode M.
  86.  
  87.      For an operand that must be a register, PREDICATE should be
  88.      `"register_operand"'.  Using `"general_operand"' would be valid,
  89.      since the reload pass would copy any non-register operands through
  90.      registers, but this would make GNU CC do extra work, it would
  91.      prevent invariant operands (such as constant) from being removed
  92.      from loops, and it would prevent the register allocator from doing
  93.      the best possible job.  On RISC machines, it is usually most
  94.      efficient to allow PREDICATE to accept only objects that the
  95.      constraints allow.
  96.  
  97.      For an operand that must be a constant, you must be sure to either
  98.      use `"immediate_operand"' for PREDICATE, or make the instruction
  99.      pattern's extra condition require a constant, or both.  You cannot
  100.      expect the constraints to do this work!  If the constraints allow
  101.      only constants, but the predicate allows something else, the
  102.      compiler will crash when that case arises.
  103.  
  104. `(match_scratch:M N CONSTRAINT)'
  105.      This expression is also a placeholder for operand number N and
  106.      indicates that operand must be a `scratch' or `reg' expression.
  107.  
  108.      When matching patterns, this is completely equivalent to
  109.  
  110.           (match_operand:M N "scratch_operand" PRED)
  111.  
  112.      but, when generating RTL, it produces a (`scratch':M) expression.
  113.  
  114.      If the last few expressions in a `parallel' are `clobber'
  115.      expressions whose operands are either a hard register or
  116.      `match_scratch', the combiner can add them when necessary.  *Note
  117.      Side Effects::.
  118.  
  119. `(match_dup N)'
  120.      This expression is also a placeholder for operand number N.  It is
  121.      used when the operand needs to appear more than once in the insn.
  122.  
  123.      In construction, `match_dup' behaves exactly like `match_operand':
  124.      the operand is substituted into the insn being constructed.  But
  125.      in matching, `match_dup' behaves differently.  It assumes that
  126.      operand number N has already been determined by a `match_operand'
  127.      appearing earlier in the recognition template, and it matches only
  128.      an identical-looking expression.
  129.  
  130. `(match_operator:M N PREDICATE [OPERANDS...])'
  131.      This pattern is a kind of placeholder for a variable RTL expression
  132.      code.
  133.  
  134.      When constructing an insn, it stands for an RTL expression whose
  135.      expression code is taken from that of operand N, and whose
  136.      operands are constructed from the patterns OPERANDS.
  137.  
  138.      When matching an expression, it matches an expression if the
  139.      function PREDICATE returns nonzero on that expression *and* the
  140.      patterns OPERANDS match the operands of the expression.
  141.  
  142.      Suppose that the function `commutative_operator' is defined as
  143.      follows, to match any expression whose operator is one of the
  144.      commutative arithmetic operators of RTL and whose mode is MODE:
  145.  
  146.           int
  147.           commutative_operator (x, mode)
  148.                rtx x;
  149.                enum machine_mode mode;
  150.           {
  151.             enum rtx_code code = GET_CODE (x);
  152.             if (GET_MODE (x) != mode)
  153.               return 0;
  154.             return (GET_RTX_CLASS (code) == 'c'
  155.                     || code == EQ || code == NE);
  156.           }
  157.  
  158.      Then the following pattern will match any RTL expression consisting
  159.      of a commutative operator applied to two general operands:
  160.  
  161.           (match_operator:SI 3 "commutative_operator"
  162.             [(match_operand:SI 1 "general_operand" "g")
  163.              (match_operand:SI 2 "general_operand" "g")])
  164.  
  165.      Here the vector `[OPERANDS...]' contains two patterns because the
  166.      expressions to be matched all contain two operands.
  167.  
  168.      When this pattern does match, the two operands of the commutative
  169.      operator are recorded as operands 1 and 2 of the insn.  (This is
  170.      done by the two instances of `match_operand'.)  Operand 3 of the
  171.      insn will be the entire commutative expression: use `GET_CODE
  172.      (operands[3])' to see which commutative operator was used.
  173.  
  174.      The machine mode M of `match_operator' works like that of
  175.      `match_operand': it is passed as the second argument to the
  176.      predicate function, and that function is solely responsible for
  177.      deciding whether the expression to be matched "has" that mode.
  178.  
  179.      When constructing an insn, argument 3 of the gen-function will
  180.      specify the operation (i.e. the expression code) for the
  181.      expression to be made.  It should be an RTL expression, whose
  182.      expression code is copied into a new expression whose operands are
  183.      arguments 1 and 2 of the gen-function.  The subexpressions of
  184.      argument 3 are not used; only its expression code matters.
  185.  
  186.      When `match_operator' is used in a pattern for matching an insn,
  187.      it usually best if the operand number of the `match_operator' is
  188.      higher than that of the actual operands of the insn.  This improves
  189.      register allocation because the register allocator often looks at
  190.      operands 1 and 2 of insns to see if it can do register tying.
  191.  
  192.      There is no way to specify constraints in `match_operator'.  The
  193.      operand of the insn which corresponds to the `match_operator'
  194.      never has any constraints because it is never reloaded as a whole.
  195.      However, if parts of its OPERANDS are matched by `match_operand'
  196.      patterns, those parts may have constraints of their own.
  197.  
  198. `(match_op_dup:M N[OPERANDS...])'
  199.      Like `match_dup', except that it applies to operators instead of
  200.      operands.  When constructing an insn, operand number N will be
  201.      substituted at this point.  But in matching, `match_op_dup' behaves
  202.      differently.  It assumes that operand number N has already been
  203.      determined by a `match_operator' appearing earlier in the
  204.      recognition template, and it matches only an identical-looking
  205.      expression.
  206.  
  207. `(match_parallel N PREDICATE [SUBPAT...])'
  208.      This pattern is a placeholder for an insn that consists of a
  209.      `parallel' expression with a variable number of elements.  This
  210.      expression should only appear at the top level of an insn pattern.
  211.  
  212.      When constructing an insn, operand number N will be substituted at
  213.      this point.  When matching an insn, it matches if the body of the
  214.      insn is a `parallel' expression with at least as many elements as
  215.      the vector of SUBPAT expressions in the `match_parallel', if each
  216.      SUBPAT matches the corresponding element of the `parallel', *and*
  217.      the function PREDICATE returns nonzero on the `parallel' that is
  218.      the body of the insn.  It is the responsibility of the predicate
  219.      to validate elements of the `parallel' beyond those listed in the
  220.      `match_parallel'.
  221.  
  222.      A typical use of `match_parallel' is to match load and store
  223.      multiple expressions, which can contains a variable number of
  224.      elements in a `parallel'.  For example,
  225.  
  226.           (define_insn ""
  227.             [(match_parallel 0 "load_multiple_operation"
  228.                [(set (match_operand:SI 1 "gpc_reg_operand" "=r")
  229.                      (match_operand:SI 2 "memory_operand" "m"))
  230.                 (use (reg:SI 179))
  231.                 (clobber (reg:SI 179))])]
  232.             ""
  233.             "loadm 0,0,%1,%2")
  234.  
  235.      This example comes from `a29k.md'.  The function
  236.      `load_multiple_operations' is defined in `a29k.c' and checks that
  237.      subsequent elements in the `parallel' are the same as the `set' in
  238.      the pattern, except that they are referencing subsequent registers
  239.      and memory locations.
  240.  
  241.      An insn that matches this pattern might look like:
  242.  
  243.           (parallel
  244.            [(set (reg:SI 20) (mem:SI (reg:SI 100)))
  245.             (use (reg:SI 179))
  246.             (clobber (reg:SI 179))
  247.             (set (reg:SI 21)
  248.                  (mem:SI (plus:SI (reg:SI 100)
  249.                                   (const_int 4))))
  250.             (set (reg:SI 22)
  251.                  (mem:SI (plus:SI (reg:SI 100)
  252.                                   (const_int 8))))])
  253.  
  254. `(match_par_dup N [SUBPAT...])'
  255.      Like `match_op_dup', but for `match_parallel' instead of
  256.      `match_operator'.
  257.  
  258. `(address (match_operand:M N "address_operand" ""))'
  259.      This complex of expressions is a placeholder for an operand number
  260.      N in a "load address" instruction: an operand which specifies a
  261.      memory location in the usual way, but for which the actual operand
  262.      value used is the address of the location, not the contents of the
  263.      location.
  264.  
  265.      `address' expressions never appear in RTL code, only in machine
  266.      descriptions.  And they are used only in machine descriptions that
  267.      do not use the operand constraint feature.  When operand
  268.      constraints are in use, the letter `p' in the constraint serves
  269.      this purpose.
  270.  
  271.      M is the machine mode of the *memory location being addressed*,
  272.      not the machine mode of the address itself.  That mode is always
  273.      the same on a given target machine (it is `Pmode', which normally
  274.      is `SImode'), so there is no point in mentioning it; thus, no
  275.      machine mode is written in the `address' expression.  If some day
  276.      support is added for machines in which addresses of different
  277.      kinds of objects appear differently or are used differently (such
  278.      as the PDP-10), different formats would perhaps need different
  279.      machine modes and these modes might be written in the `address'
  280.      expression.
  281.  
  282. File: gcc.info,  Node: Output Template,  Next: Output Statement,  Prev: RTL Template,  Up: Machine Desc
  283.  
  284. Output Templates and Operand Substitution
  285. =========================================
  286.  
  287.    The "output template" is a string which specifies how to output the
  288. assembler code for an instruction pattern.  Most of the template is a
  289. fixed string which is output literally.  The character `%' is used to
  290. specify where to substitute an operand; it can also be used to identify
  291. places where different variants of the assembler require different
  292. syntax.
  293.  
  294.    In the simplest case, a `%' followed by a digit N says to output
  295. operand N at that point in the string.
  296.  
  297.    `%' followed by a letter and a digit says to output an operand in an
  298. alternate fashion.  Four letters have standard, built-in meanings
  299. described below.  The machine description macro `PRINT_OPERAND' can
  300. define additional letters with nonstandard meanings.
  301.  
  302.    `%cDIGIT' can be used to substitute an operand that is a constant
  303. value without the syntax that normally indicates an immediate operand.
  304.  
  305.    `%nDIGIT' is like `%cDIGIT' except that the value of the constant is
  306. negated before printing.
  307.  
  308.    `%aDIGIT' can be used to substitute an operand as if it were a
  309. memory reference, with the actual operand treated as the address.  This
  310. may be useful when outputting a "load address" instruction, because
  311. often the assembler syntax for such an instruction requires you to
  312. write the operand as if it were a memory reference.
  313.  
  314.    `%lDIGIT' is used to substitute a `label_ref' into a jump
  315. instruction.
  316.  
  317.    `%=' outputs a number which is unique to each instruction in the
  318. entire compilation.  This is useful for making local labels to be
  319. referred to more than once in a single template that generates multiple
  320. assembler instructions.
  321.  
  322.    `%' followed by a punctuation character specifies a substitution that
  323. does not use an operand.  Only one case is standard: `%%' outputs a `%'
  324. into the assembler code.  Other nonstandard cases can be defined in the
  325. `PRINT_OPERAND' macro.  You must also define which punctuation
  326. characters are valid with the `PRINT_OPERAND_PUNCT_VALID_P' macro.
  327.  
  328.    The template may generate multiple assembler instructions.  Write
  329. the text for the instructions, with `\;' between them.
  330.  
  331.    When the RTL contains two operands which are required by constraint
  332. to match each other, the output template must refer only to the
  333. lower-numbered operand.  Matching operands are not always identical,
  334. and the rest of the compiler arranges to put the proper RTL expression
  335. for printing into the lower-numbered operand.
  336.  
  337.    One use of nonstandard letters or punctuation following `%' is to
  338. distinguish between different assembler languages for the same machine;
  339. for example, Motorola syntax versus MIT syntax for the 68000.  Motorola
  340. syntax requires periods in most opcode names, while MIT syntax does
  341. not.  For example, the opcode `movel' in MIT syntax is `move.l' in
  342. Motorola syntax.  The same file of patterns is used for both kinds of
  343. output syntax, but the character sequence `%.' is used in each place
  344. where Motorola syntax wants a period.  The `PRINT_OPERAND' macro for
  345. Motorola syntax defines the sequence to output a period; the macro for
  346. MIT syntax defines it to do nothing.
  347.  
  348.    As a special case, a template consisting of the single character `#'
  349. instructs the compiler to first split the insn, and then output the
  350. resulting instructions separately.  This helps eliminate redundancy in
  351. the output templates.   If you have a `define_insn' that needs to emit
  352. multiple assembler instructions, and there is an matching `define_split'
  353. already defined, then you can simply use `#' as the output template
  354. instead of writing an output template that emits the multiple assembler
  355. instructions.
  356.  
  357. File: gcc.info,  Node: Output Statement,  Next: Constraints,  Prev: Output Template,  Up: Machine Desc
  358.  
  359. C Statements for Generating Assembler Output
  360. ============================================
  361.  
  362.    Often a single fixed template string cannot produce correct and
  363. efficient assembler code for all the cases that are recognized by a
  364. single instruction pattern.  For example, the opcodes may depend on the
  365. kinds of operands; or some unfortunate combinations of operands may
  366. require extra machine instructions.
  367.  
  368.    If the output control string starts with a `@', then it is actually
  369. a series of templates, each on a separate line.  (Blank lines and
  370. leading spaces and tabs are ignored.)  The templates correspond to the
  371. pattern's constraint alternatives (*note Multi-Alternative::.).  For
  372. example, if a target machine has a two-address add instruction `addr'
  373. to add into a register and another `addm' to add a register to memory,
  374. you might write this pattern:
  375.  
  376.      (define_insn "addsi3"
  377.        [(set (match_operand:SI 0 "general_operand" "=r,m")
  378.              (plus:SI (match_operand:SI 1 "general_operand" "0,0")
  379.                       (match_operand:SI 2 "general_operand" "g,r")))]
  380.        ""
  381.        "@
  382.         addr %2,%0
  383.         addm %2,%0")
  384.  
  385.    If the output control string starts with a `*', then it is not an
  386. output template but rather a piece of C program that should compute a
  387. template.  It should execute a `return' statement to return the
  388. template-string you want.  Most such templates use C string literals,
  389. which require doublequote characters to delimit them.  To include these
  390. doublequote characters in the string, prefix each one with `\'.
  391.  
  392.    The operands may be found in the array `operands', whose C data type
  393. is `rtx []'.
  394.  
  395.    It is very common to select different ways of generating assembler
  396. code based on whether an immediate operand is within a certain range.
  397. Be careful when doing this, because the result of `INTVAL' is an
  398. integer on the host machine.  If the host machine has more bits in an
  399. `int' than the target machine has in the mode in which the constant
  400. will be used, then some of the bits you get from `INTVAL' will be
  401. superfluous.  For proper results, you must carefully disregard the
  402. values of those bits.
  403.  
  404.    It is possible to output an assembler instruction and then go on to
  405. output or compute more of them, using the subroutine `output_asm_insn'.
  406. This receives two arguments: a template-string and a vector of
  407. operands.  The vector may be `operands', or it may be another array of
  408. `rtx' that you declare locally and initialize yourself.
  409.  
  410.    When an insn pattern has multiple alternatives in its constraints,
  411. often the appearance of the assembler code is determined mostly by
  412. which alternative was matched.  When this is so, the C code can test
  413. the variable `which_alternative', which is the ordinal number of the
  414. alternative that was actually satisfied (0 for the first, 1 for the
  415. second alternative, etc.).
  416.  
  417.    For example, suppose there are two opcodes for storing zero, `clrreg'
  418. for registers and `clrmem' for memory locations.  Here is how a pattern
  419. could use `which_alternative' to choose between them:
  420.  
  421.      (define_insn ""
  422.        [(set (match_operand:SI 0 "general_operand" "=r,m")
  423.              (const_int 0))]
  424.        ""
  425.        "*
  426.        return (which_alternative == 0
  427.                ? \"clrreg %0\" : \"clrmem %0\");
  428.        ")
  429.  
  430.    The example above, where the assembler code to generate was *solely*
  431. determined by the alternative, could also have been specified as
  432. follows, having the output control string start with a `@':
  433.  
  434.      (define_insn ""
  435.        [(set (match_operand:SI 0 "general_operand" "=r,m")
  436.              (const_int 0))]
  437.        ""
  438.        "@
  439.         clrreg %0
  440.         clrmem %0")
  441.  
  442. File: gcc.info,  Node: Constraints,  Next: Standard Names,  Prev: Output Statement,  Up: Machine Desc
  443.  
  444. Operand Constraints
  445. ===================
  446.  
  447.    Each `match_operand' in an instruction pattern can specify a
  448. constraint for the type of operands allowed.  Constraints can say
  449. whether an operand may be in a register, and which kinds of register;
  450. whether the operand can be a memory reference, and which kinds of
  451. address; whether the operand may be an immediate constant, and which
  452. possible values it may have.  Constraints can also require two operands
  453. to match.
  454.  
  455. * Menu:
  456.  
  457. * Simple Constraints::  Basic use of constraints.
  458. * Multi-Alternative::   When an insn has two alternative constraint-patterns.
  459. * Class Preferences::   Constraints guide which hard register to put things in.
  460. * Modifiers::           More precise control over effects of constraints.
  461. * Machine Constraints:: Existing constraints for some particular machines.
  462. * No Constraints::      Describing a clean machine without constraints.
  463.  
  464. File: gcc.info,  Node: Simple Constraints,  Next: Multi-Alternative,  Up: Constraints
  465.  
  466. Simple Constraints
  467. ------------------
  468.  
  469.    The simplest kind of constraint is a string full of letters, each of
  470. which describes one kind of operand that is permitted.  Here are the
  471. letters that are allowed:
  472.  
  473. `m'
  474.      A memory operand is allowed, with any kind of address that the
  475.      machine supports in general.
  476.  
  477. `o'
  478.      A memory operand is allowed, but only if the address is
  479.      "offsettable".  This means that adding a small integer (actually,
  480.      the width in bytes of the operand, as determined by its machine
  481.      mode) may be added to the address and the result is also a valid
  482.      memory address.
  483.  
  484.      For example, an address which is constant is offsettable; so is an
  485.      address that is the sum of a register and a constant (as long as a
  486.      slightly larger constant is also within the range of
  487.      address-offsets supported by the machine); but an autoincrement or
  488.      autodecrement address is not offsettable.  More complicated
  489.      indirect/indexed addresses may or may not be offsettable depending
  490.      on the other addressing modes that the machine supports.
  491.  
  492.      Note that in an output operand which can be matched by another
  493.      operand, the constraint letter `o' is valid only when accompanied
  494.      by both `<' (if the target machine has predecrement addressing)
  495.      and `>' (if the target machine has preincrement addressing).
  496.  
  497. `V'
  498.      A memory operand that is not offsettable.  In other words,
  499.      anything that would fit the `m' constraint but not the `o'
  500.      constraint.
  501.  
  502. `<'
  503.      A memory operand with autodecrement addressing (either
  504.      predecrement or postdecrement) is allowed.
  505.  
  506. `>'
  507.      A memory operand with autoincrement addressing (either
  508.      preincrement or postincrement) is allowed.
  509.  
  510. `r'
  511.      A register operand is allowed provided that it is in a general
  512.      register.
  513.  
  514. `d', `a', `f', ...
  515.      Other letters can be defined in machine-dependent fashion to stand
  516.      for particular classes of registers.  `d', `a' and `f' are defined
  517.      on the 68000/68020 to stand for data, address and floating point
  518.      registers.
  519.  
  520. `i'
  521.      An immediate integer operand (one with constant value) is allowed.
  522.      This includes symbolic constants whose values will be known only at
  523.      assembly time.
  524.  
  525. `n'
  526.      An immediate integer operand with a known numeric value is allowed.
  527.      Many systems cannot support assembly-time constants for operands
  528.      less than a word wide.  Constraints for these operands should use
  529.      `n' rather than `i'.
  530.  
  531. `I', `J', `K', ... `P'
  532.      Other letters in the range `I' through `P' may be defined in a
  533.      machine-dependent fashion to permit immediate integer operands with
  534.      explicit integer values in specified ranges.  For example, on the
  535.      68000, `I' is defined to stand for the range of values 1 to 8.
  536.      This is the range permitted as a shift count in the shift
  537.      instructions.
  538.  
  539. `E'
  540.      An immediate floating operand (expression code `const_double') is
  541.      allowed, but only if the target floating point format is the same
  542.      as that of the host machine (on which the compiler is running).
  543.  
  544. `F'
  545.      An immediate floating operand (expression code `const_double') is
  546.      allowed.
  547.  
  548. `G', `H'
  549.      `G' and `H' may be defined in a machine-dependent fashion to
  550.      permit immediate floating operands in particular ranges of values.
  551.  
  552. `s'
  553.      An immediate integer operand whose value is not an explicit
  554.      integer is allowed.
  555.  
  556.      This might appear strange; if an insn allows a constant operand
  557.      with a value not known at compile time, it certainly must allow
  558.      any known value.  So why use `s' instead of `i'?  Sometimes it
  559.      allows better code to be generated.
  560.  
  561.      For example, on the 68000 in a fullword instruction it is possible
  562.      to use an immediate operand; but if the immediate value is between
  563.      -128 and 127, better code results from loading the value into a
  564.      register and using the register.  This is because the load into
  565.      the register can be done with a `moveq' instruction.  We arrange
  566.      for this to happen by defining the letter `K' to mean "any integer
  567.      outside the range -128 to 127", and then specifying `Ks' in the
  568.      operand constraints.
  569.  
  570. `g'
  571.      Any register, memory or immediate integer operand is allowed,
  572.      except for registers that are not general registers.
  573.  
  574. `X'
  575.      Any operand whatsoever is allowed, even if it does not satisfy
  576.      `general_operand'.  This is normally used in the constraint of a
  577.      `match_scratch' when certain alternatives will not actually
  578.      require a scratch register.
  579.  
  580. `0', `1', `2', ... `9'
  581.      An operand that matches the specified operand number is allowed.
  582.      If a digit is used together with letters within the same
  583.      alternative, the digit should come last.
  584.  
  585.      This is called a "matching constraint" and what it really means is
  586.      that the assembler has only a single operand that fills two roles
  587.      considered separate in the RTL insn.  For example, an add insn has
  588.      two input operands and one output operand in the RTL, but on most
  589.      CISC machines an add instruction really has only two operands, one
  590.      of them an input-output operand:
  591.  
  592.           addl #35,r12
  593.  
  594.      Matching constraints are used in these circumstances.  More
  595.      precisely, the two operands that match must include one input-only
  596.      operand and one output-only operand.  Moreover, the digit must be a
  597.      smaller number than the number of the operand that uses it in the
  598.      constraint.
  599.  
  600.      For operands to match in a particular case usually means that they
  601.      are identical-looking RTL expressions.  But in a few special cases
  602.      specific kinds of dissimilarity are allowed.  For example, `*x' as
  603.      an input operand will match `*x++' as an output operand.  For
  604.      proper results in such cases, the output template should always
  605.      use the output-operand's number when printing the operand.
  606.  
  607. `p'
  608.      An operand that is a valid memory address is allowed.  This is for
  609.      "load address" and "push address" instructions.
  610.  
  611.      `p' in the constraint must be accompanied by `address_operand' as
  612.      the predicate in the `match_operand'.  This predicate interprets
  613.      the mode specified in the `match_operand' as the mode of the memory
  614.      reference for which the address would be valid.
  615.  
  616. `Q', `R', `S', ... `U'
  617.      Letters in the range `Q' through `U' may be defined in a
  618.      machine-dependent fashion to stand for arbitrary operand types.
  619.      The machine description macro `EXTRA_CONSTRAINT' is passed the
  620.      operand as its first argument and the constraint letter as its
  621.      second operand.
  622.  
  623.      A typical use for this would be to distinguish certain types of
  624.      memory references that affect other insn operands.
  625.  
  626.      Do not define these constraint letters to accept register
  627.      references (`reg'); the reload pass does not expect this and would
  628.      not handle it properly.
  629.  
  630.    In order to have valid assembler code, each operand must satisfy its
  631. constraint.  But a failure to do so does not prevent the pattern from
  632. applying to an insn.  Instead, it directs the compiler to modify the
  633. code so that the constraint will be satisfied.  Usually this is done by
  634. copying an operand into a register.
  635.  
  636.    Contrast, therefore, the two instruction patterns that follow:
  637.  
  638.      (define_insn ""
  639.        [(set (match_operand:SI 0 "general_operand" "=r")
  640.              (plus:SI (match_dup 0)
  641.                       (match_operand:SI 1 "general_operand" "r")))]
  642.        ""
  643.        "...")
  644.  
  645. which has two operands, one of which must appear in two places, and
  646.  
  647.      (define_insn ""
  648.        [(set (match_operand:SI 0 "general_operand" "=r")
  649.              (plus:SI (match_operand:SI 1 "general_operand" "0")
  650.                       (match_operand:SI 2 "general_operand" "r")))]
  651.        ""
  652.        "...")
  653.  
  654. which has three operands, two of which are required by a constraint to
  655. be identical.  If we are considering an insn of the form
  656.  
  657.      (insn N PREV NEXT
  658.        (set (reg:SI 3)
  659.             (plus:SI (reg:SI 6) (reg:SI 109)))
  660.        ...)
  661.  
  662. the first pattern would not apply at all, because this insn does not
  663. contain two identical subexpressions in the right place.  The pattern
  664. would say, "That does not look like an add instruction; try other
  665. patterns." The second pattern would say, "Yes, that's an add
  666. instruction, but there is something wrong with it."  It would direct
  667. the reload pass of the compiler to generate additional insns to make
  668. the constraint true.  The results might look like this:
  669.  
  670.      (insn N2 PREV N
  671.        (set (reg:SI 3) (reg:SI 6))
  672.        ...)
  673.      
  674.      (insn N N2 NEXT
  675.        (set (reg:SI 3)
  676.             (plus:SI (reg:SI 3) (reg:SI 109)))
  677.        ...)
  678.  
  679.    It is up to you to make sure that each operand, in each pattern, has
  680. constraints that can handle any RTL expression that could be present for
  681. that operand.  (When multiple alternatives are in use, each pattern
  682. must, for each possible combination of operand expressions, have at
  683. least one alternative which can handle that combination of operands.)
  684. The constraints don't need to *allow* any possible operand--when this is
  685. the case, they do not constrain--but they must at least point the way to
  686. reloading any possible operand so that it will fit.
  687.  
  688.    * If the constraint accepts whatever operands the predicate permits,
  689.      there is no problem: reloading is never necessary for this operand.
  690.  
  691.      For example, an operand whose constraints permit everything except
  692.      registers is safe provided its predicate rejects registers.
  693.  
  694.      An operand whose predicate accepts only constant values is safe
  695.      provided its constraints include the letter `i'.  If any possible
  696.      constant value is accepted, then nothing less than `i' will do; if
  697.      the predicate is more selective, then the constraints may also be
  698.      more selective.
  699.  
  700.    * Any operand expression can be reloaded by copying it into a
  701.      register.  So if an operand's constraints allow some kind of
  702.      register, it is certain to be safe.  It need not permit all
  703.      classes of registers; the compiler knows how to copy a register
  704.      into another register of the proper class in order to make an
  705.      instruction valid.
  706.  
  707.    * A nonoffsettable memory reference can be reloaded by copying the
  708.      address into a register.  So if the constraint uses the letter
  709.      `o', all memory references are taken care of.
  710.  
  711.    * A constant operand can be reloaded by allocating space in memory to
  712.      hold it as preinitialized data.  Then the memory reference can be
  713.      used in place of the constant.  So if the constraint uses the
  714.      letters `o' or `m', constant operands are not a problem.
  715.  
  716.    * If the constraint permits a constant and a pseudo register used in
  717.      an insn was not allocated to a hard register and is equivalent to
  718.      a constant, the register will be replaced with the constant.  If
  719.      the predicate does not permit a constant and the insn is
  720.      re-recognized for some reason, the compiler will crash.  Thus the
  721.      predicate must always recognize any objects allowed by the
  722.      constraint.
  723.  
  724.    If the operand's predicate can recognize registers, but the
  725. constraint does not permit them, it can make the compiler crash.  When
  726. this operand happens to be a register, the reload pass will be stymied,
  727. because it does not know how to copy a register temporarily into memory.
  728.  
  729. File: gcc.info,  Node: Multi-Alternative,  Next: Class Preferences,  Prev: Simple Constraints,  Up: Constraints
  730.  
  731. Multiple Alternative Constraints
  732. --------------------------------
  733.  
  734.    Sometimes a single instruction has multiple alternative sets of
  735. possible operands.  For example, on the 68000, a logical-or instruction
  736. can combine register or an immediate value into memory, or it can
  737. combine any kind of operand into a register; but it cannot combine one
  738. memory location into another.
  739.  
  740.    These constraints are represented as multiple alternatives.  An
  741. alternative can be described by a series of letters for each operand.
  742. The overall constraint for an operand is made from the letters for this
  743. operand from the first alternative, a comma, the letters for this
  744. operand from the second alternative, a comma, and so on until the last
  745. alternative.  Here is how it is done for fullword logical-or on the
  746. 68000:
  747.  
  748.      (define_insn "iorsi3"
  749.        [(set (match_operand:SI 0 "general_operand" "=m,d")
  750.              (ior:SI (match_operand:SI 1 "general_operand" "%0,0")
  751.                      (match_operand:SI 2 "general_operand" "dKs,dmKs")))]
  752.        ...)
  753.  
  754.    The first alternative has `m' (memory) for operand 0, `0' for
  755. operand 1 (meaning it must match operand 0), and `dKs' for operand 2.
  756. The second alternative has `d' (data register) for operand 0, `0' for
  757. operand 1, and `dmKs' for operand 2.  The `=' and `%' in the
  758. constraints apply to all the alternatives; their meaning is explained
  759. in the next section (*note Class Preferences::.).
  760.  
  761.    If all the operands fit any one alternative, the instruction is
  762. valid.  Otherwise, for each alternative, the compiler counts how many
  763. instructions must be added to copy the operands so that that
  764. alternative applies.  The alternative requiring the least copying is
  765. chosen.  If two alternatives need the same amount of copying, the one
  766. that comes first is chosen.  These choices can be altered with the `?'
  767. and `!' characters:
  768.  
  769. `?'
  770.      Disparage slightly the alternative that the `?' appears in, as a
  771.      choice when no alternative applies exactly.  The compiler regards
  772.      this alternative as one unit more costly for each `?' that appears
  773.      in it.
  774.  
  775. `!'
  776.      Disparage severely the alternative that the `!' appears in.  This
  777.      alternative can still be used if it fits without reloading, but if
  778.      reloading is needed, some other alternative will be used.
  779.  
  780.    When an insn pattern has multiple alternatives in its constraints,
  781. often the appearance of the assembler code is determined mostly by which
  782. alternative was matched.  When this is so, the C code for writing the
  783. assembler code can use the variable `which_alternative', which is the
  784. ordinal number of the alternative that was actually satisfied (0 for
  785. the first, 1 for the second alternative, etc.).  *Note Output
  786. Statement::.
  787.  
  788. File: gcc.info,  Node: Class Preferences,  Next: Modifiers,  Prev: Multi-Alternative,  Up: Constraints
  789.  
  790. Register Class Preferences
  791. --------------------------
  792.  
  793.    The operand constraints have another function: they enable the
  794. compiler to decide which kind of hardware register a pseudo register is
  795. best allocated to.  The compiler examines the constraints that apply to
  796. the insns that use the pseudo register, looking for the
  797. machine-dependent letters such as `d' and `a' that specify classes of
  798. registers.  The pseudo register is put in whichever class gets the most
  799. "votes".  The constraint letters `g' and `r' also vote: they vote in
  800. favor of a general register.  The machine description says which
  801. registers are considered general.
  802.  
  803.    Of course, on some machines all registers are equivalent, and no
  804. register classes are defined.  Then none of this complexity is relevant.
  805.  
  806. File: gcc.info,  Node: Modifiers,  Next: Machine Constraints,  Prev: Class Preferences,  Up: Constraints
  807.  
  808. Constraint Modifier Characters
  809. ------------------------------
  810.  
  811. `='
  812.      Means that this operand is write-only for this instruction: the
  813.      previous value is discarded and replaced by output data.
  814.  
  815. `+'
  816.      Means that this operand is both read and written by the
  817.      instruction.
  818.  
  819.      When the compiler fixes up the operands to satisfy the constraints,
  820.      it needs to know which operands are inputs to the instruction and
  821.      which are outputs from it.  `=' identifies an output; `+'
  822.      identifies an operand that is both input and output; all other
  823.      operands are assumed to be input only.
  824.  
  825. `&'
  826.      Means (in a particular alternative) that this operand is written
  827.      before the instruction is finished using the input operands.
  828.      Therefore, this operand may not lie in a register that is used as
  829.      an input operand or as part of any memory address.
  830.  
  831.      `&' applies only to the alternative in which it is written.  In
  832.      constraints with multiple alternatives, sometimes one alternative
  833.      requires `&' while others do not.  See, for example, the `movdf'
  834.      insn of the 68000.
  835.  
  836.      `&' does not obviate the need to write `='.
  837.  
  838. `%'
  839.      Declares the instruction to be commutative for this operand and the
  840.      following operand.  This means that the compiler may interchange
  841.      the two operands if that is the cheapest way to make all operands
  842.      fit the constraints.  This is often used in patterns for addition
  843.      instructions that really have only two operands: the result must
  844.      go in one of the arguments.  Here for example, is how the 68000
  845.      halfword-add instruction is defined:
  846.  
  847.           (define_insn "addhi3"
  848.             [(set (match_operand:HI 0 "general_operand" "=m,r")
  849.                (plus:HI (match_operand:HI 1 "general_operand" "%0,0")
  850.                         (match_operand:HI 2 "general_operand" "di,g")))]
  851.             ...)
  852.  
  853. `#'
  854.      Says that all following characters, up to the next comma, are to be
  855.      ignored as a constraint.  They are significant only for choosing
  856.      register preferences.
  857.  
  858. `*'
  859.      Says that the following character should be ignored when choosing
  860.      register preferences.  `*' has no effect on the meaning of the
  861.      constraint as a constraint, and no effect on reloading.
  862.  
  863.      Here is an example: the 68000 has an instruction to sign-extend a
  864.      halfword in a data register, and can also sign-extend a value by
  865.      copying it into an address register.  While either kind of
  866.      register is acceptable, the constraints on an address-register
  867.      destination are less strict, so it is best if register allocation
  868.      makes an address register its goal.  Therefore, `*' is used so
  869.      that the `d' constraint letter (for data register) is ignored when
  870.      computing register preferences.
  871.  
  872.           (define_insn "extendhisi2"
  873.             [(set (match_operand:SI 0 "general_operand" "=*d,a")
  874.                   (sign_extend:SI
  875.                    (match_operand:HI 1 "general_operand" "0,g")))]
  876.             ...)
  877.  
  878. File: gcc.info,  Node: Machine Constraints,  Next: No Constraints,  Prev: Modifiers,  Up: Constraints
  879.  
  880. Constraints for Particular Machines
  881. -----------------------------------
  882.  
  883.    Whenever possible, you should use the general-purpose constraint
  884. letters in `asm' arguments, since they will convey meaning more readily
  885. to people reading your code.  Failing that, use the constraint letters
  886. that usually have very similar meanings across architectures.  The most
  887. commonly used constraints are `m' and `r' (for memory and
  888. general-purpose registers respectively; *note Simple Constraints::.),
  889. and `I', usually the letter indicating the most common
  890. immediate-constant format.
  891.  
  892.    For each machine architecture, the `config/MACHINE.h' file defines
  893. additional constraints.  These constraints are used by the compiler
  894. itself for instruction generation, as well as for `asm' statements;
  895. therefore, some of the constraints are not particularly interesting for
  896. `asm'.  The constraints are defined through these macros:
  897.  
  898. `REG_CLASS_FROM_LETTER'
  899.      Register class constraints (usually lower case).
  900.  
  901. `CONST_OK_FOR_LETTER_P'
  902.      Immediate constant constraints, for non-floating point constants of
  903.      word size or smaller precision (usually upper case).
  904.  
  905. `CONST_DOUBLE_OK_FOR_LETTER_P'
  906.      Immediate constant constraints, for all floating point constants
  907.      and for constants of greater than word size precision (usually
  908.      upper case).
  909.  
  910. `EXTRA_CONSTRAINTS'
  911.      Special cases of registers or memory.  This macro is not required,
  912.      and is only defined for some machines.
  913.  
  914.    Inspecting these macro definitions in the compiler source for your
  915. machine is the best way to be certain you have the right constraints.
  916. However, here is a summary of the machine-dependent constraints
  917. available on some particular machines.
  918.  
  919. *AMD 29000 family--`a29k.h'*
  920.     `l'
  921.           Local register 0
  922.  
  923.     `b'
  924.           Byte Pointer (`BP') register
  925.  
  926.     `q'
  927.           `Q' register
  928.  
  929.     `h'
  930.           Special purpose register
  931.  
  932.     `A'
  933.           First accumulator register
  934.  
  935.     `a'
  936.           Other accumulator register
  937.  
  938.     `f'
  939.           Floating point register
  940.  
  941.     `I'
  942.           Constant greater than 0, less than 0x100
  943.  
  944.     `J'
  945.           Constant greater than 0, less than 0x10000
  946.  
  947.     `K'
  948.           Constant whose high 24 bits are on (1)
  949.  
  950.     `L'
  951.           16 bit constant whose high 8 bits are on (1)
  952.  
  953.     `M'
  954.           32 bit constant whose high 16 bits are on (1)
  955.  
  956.     `N'
  957.           32 bit negative constant that fits in 8 bits
  958.  
  959.     `O'
  960.           The constant 0x80000000 or, on the 29050, any 32 bit constant
  961.           whose low 16 bits are 0.
  962.  
  963.     `P'
  964.           16 bit negative constant that fits in 8 bits
  965.  
  966.     `G'
  967.     `H'
  968.           A floating point constant (in `asm' statements, use the
  969.           machine independent `E' or `F' instead)
  970.  
  971. *IBM RS6000--`rs6000.h'*
  972.     `b'
  973.           Address base register
  974.  
  975.     `f'
  976.           Floating point register
  977.  
  978.     `h'
  979.           `MQ', `CTR', or `LINK' register
  980.  
  981.     `q'
  982.           `MQ' register
  983.  
  984.     `c'
  985.           `CTR' register
  986.  
  987.     `l'
  988.           `LINK' register
  989.  
  990.     `x'
  991.           `CR' register (condition register) number 0
  992.  
  993.     `y'
  994.           `CR' register (condition register)
  995.  
  996.     `I'
  997.           Signed 16 bit constant
  998.  
  999.     `J'
  1000.           Constant whose low 16 bits are 0
  1001.  
  1002.     `K'
  1003.           Constant whose high 16 bits are 0
  1004.  
  1005.     `L'
  1006.           Constant suitable as a mask operand
  1007.  
  1008.     `M'
  1009.           Constant larger than 31
  1010.  
  1011.     `N'
  1012.           Exact power of 2
  1013.  
  1014.     `O'
  1015.           Zero
  1016.  
  1017.     `P'
  1018.           Constant whose negation is a signed 16 bit constant
  1019.  
  1020.     `G'
  1021.           Floating point constant that can be loaded into a register
  1022.           with one instruction per word
  1023.  
  1024.     `Q'
  1025.           Memory operand that is an offset from a register (`m' is
  1026.           preferable for `asm' statements)
  1027.  
  1028. *Intel 386--`i386.h'*
  1029.     `q'
  1030.           `a', `b', `c', or `d' register
  1031.  
  1032.     `f'
  1033.           Floating point register
  1034.  
  1035.     `t'
  1036.           First (top of stack) floating point register
  1037.  
  1038.     `u'
  1039.           Second floating point register
  1040.  
  1041.     `a'
  1042.           `a' register
  1043.  
  1044.     `b'
  1045.           `b' register
  1046.  
  1047.     `c'
  1048.           `c' register
  1049.  
  1050.     `d'
  1051.           `d' register
  1052.  
  1053.     `D'
  1054.           `di' register
  1055.  
  1056.     `S'
  1057.           `si' register
  1058.  
  1059.     `I'
  1060.           Constant in range 0 to 31 (for 32 bit shifts)
  1061.  
  1062.     `J'
  1063.           Constant in range 0 to 63 (for 64 bit shifts)
  1064.  
  1065.     `K'
  1066.           `0xff'
  1067.  
  1068.     `L'
  1069.           `0xffff'
  1070.  
  1071.     `M'
  1072.           0, 1, 2, or 3 (shifts for `lea' instruction)
  1073.  
  1074.     `G'
  1075.           Standard 80387 floating point constant
  1076.  
  1077. *Intel 960--`i960.h'*
  1078.     `f'
  1079.           Floating point register (`fp0' to `fp3')
  1080.  
  1081.     `l'
  1082.           Local register (`r0' to `r15')
  1083.  
  1084.     `b'
  1085.           Global register (`g0' to `g15')
  1086.  
  1087.     `d'
  1088.           Any local or global register
  1089.  
  1090.     `I'
  1091.           Integers from 0 to 31
  1092.  
  1093.     `J'
  1094.           0
  1095.  
  1096.     `K'
  1097.           Integers from -31 to 0
  1098.  
  1099.     `G'
  1100.           Floating point 0
  1101.  
  1102.     `H'
  1103.           Floating point 1
  1104.  
  1105. *MIPS--`mips.h'*
  1106.     `d'
  1107.           General-purpose integer register
  1108.  
  1109.     `f'
  1110.           Floating-point register (if available)
  1111.  
  1112.     `h'
  1113.           `Hi' register
  1114.  
  1115.     `l'
  1116.           `Lo' register
  1117.  
  1118.     `x'
  1119.           `Hi' or `Lo' register
  1120.  
  1121.     `y'
  1122.           General-purpose integer register
  1123.  
  1124.     `z'
  1125.           Floating-point status register
  1126.  
  1127.     `I'
  1128.           Signed 16 bit constant (for arithmetic instructions)
  1129.  
  1130.     `J'
  1131.           Zero
  1132.  
  1133.     `K'
  1134.           Zero-extended 16-bit constant (for logic instructions)
  1135.  
  1136.     `L'
  1137.           Constant with low 16 bits zero (can be loaded with `lui')
  1138.  
  1139.     `M'
  1140.           32 bit constant which requires two instructions to load (a
  1141.           constant which is not `I', `K', or `L')
  1142.  
  1143.     `N'
  1144.           Negative 16 bit constant
  1145.  
  1146.     `O'
  1147.           Exact power of two
  1148.  
  1149.     `P'
  1150.           Positive 16 bit constant
  1151.  
  1152.     `G'
  1153.           Floating point zero
  1154.  
  1155.     `Q'
  1156.           Memory reference that can be loaded with more than one
  1157.           instruction (`m' is preferable for `asm' statements)
  1158.  
  1159.     `R'
  1160.           Memory reference that can be loaded with one instruction (`m'
  1161.           is preferable for `asm' statements)
  1162.  
  1163.     `S'
  1164.           Memory reference in external OSF/rose PIC format (`m' is
  1165.           preferable for `asm' statements)
  1166.  
  1167. *Motorola 680x0--`m68k.h'*
  1168.     `a'
  1169.           Address register
  1170.  
  1171.     `d'
  1172.           Data register
  1173.  
  1174.     `f'
  1175.           68881 floating-point register, if available
  1176.  
  1177.     `x'
  1178.           Sun FPA (floating-point) register, if available
  1179.  
  1180.     `y'
  1181.           First 16 Sun FPA registers, if available
  1182.  
  1183.     `I'
  1184.           Integer in the range 1 to 8
  1185.  
  1186.     `J'
  1187.           16 bit signed number
  1188.  
  1189.     `K'
  1190.           Signed number whose magnitude is greater than 0x80
  1191.  
  1192.     `L'
  1193.           Integer in the range -8 to -1
  1194.  
  1195.     `G'
  1196.           Floating point constant that is not a 68881 constant
  1197.  
  1198.     `H'
  1199.           Floating point constant that can be used by Sun FPA
  1200.  
  1201. *SPARC--`sparc.h'*
  1202.     `f'
  1203.           Floating-point register
  1204.  
  1205.     `I'
  1206.           Signed 13 bit constant
  1207.  
  1208.     `J'
  1209.           Zero
  1210.  
  1211.     `K'
  1212.           32 bit constant with the low 12 bits clear (a constant that
  1213.           can be loaded with the `sethi' instruction)
  1214.  
  1215.     `G'
  1216.           Floating-point zero
  1217.  
  1218.     `H'
  1219.           Signed 13 bit constant, sign-extended to 32 or 64 bits
  1220.  
  1221.     `Q'
  1222.           Memory reference that can be loaded with one instruction
  1223.           (`m' is more appropriate for `asm' statements)
  1224.  
  1225.     `S'
  1226.           Constant, or memory address
  1227.  
  1228.     `T'
  1229.           Memory address aligned to an 8-byte boundary
  1230.  
  1231.     `U'
  1232.           Even register
  1233.  
  1234. File: gcc.info,  Node: No Constraints,  Prev: Machine Constraints,  Up: Constraints
  1235.  
  1236. Not Using Constraints
  1237. ---------------------
  1238.  
  1239.    Some machines are so clean that operand constraints are not
  1240. required.  For example, on the Vax, an operand valid in one context is
  1241. valid in any other context.  On such a machine, every operand
  1242. constraint would be `g', excepting only operands of "load address"
  1243. instructions which are written as if they referred to a memory
  1244. location's contents but actual refer to its address.  They would have
  1245. constraint `p'.
  1246.  
  1247.    For such machines, instead of writing `g' and `p' for all the
  1248. constraints, you can choose to write a description with empty
  1249. constraints.  Then you write `""' for the constraint in every
  1250. `match_operand'.  Address operands are identified by writing an
  1251. `address' expression around the `match_operand', not by their
  1252. constraints.
  1253.  
  1254.    When the machine description has just empty constraints, certain
  1255. parts of compilation are skipped, making the compiler faster.  However,
  1256. few machines actually do not need constraints; all machine descriptions
  1257. now in existence use constraints.
  1258.  
  1259. ə